<?php
class TreeInfoVo extends SzAbstractMySqlVo
{

    private $userId;
    private $buildingId;
    private $number;
    private $level;
    private $endTime;
    private $exp;
    private $startTime;

    /**
     * Initialize TreeInfoVo.
     *
     * @param $userId
     * @param $buildingId
     * @param $number
     * @param $level
     * @param $endTime
     * @param $exp
     * @param $startTime
     * @param boolean $isInsert default false, means for now this vo is initialized not for insert process
     * @return TreeInfoVo
     */
    public function __construct($userId, $buildingId, $number, $level, $endTime, $exp, $startTime = 0, $isInsert = false) {
        $this->userId = $userId;
        $this->buildingId = $buildingId;
        $this->number = $number;
        $this->level = $level;
        $this->endTime = $endTime;
        $this->exp = $exp;
        $this->startTime = $startTime;

        $this->isInsert = $isInsert;
        $this->voClassName = 'TreeInfoVo';
        $this->ormName = 'TreeInfo';
    }

    /**
     * @see SzAbstractVo::toArray
     */
    public function toArray($needEncode = false)
    {
        return array(
            'userId' => $this->getUserId(),
            'buildingId' => $this->getBuildingId(),
            'number' => $this->getNumber(),
            'level' => $this->getLevel(),
            'endTime' => $this->getEndTime(),
            'exp' => $this->getExp(),
            'startTime' => $this->getStartTime(),
        );
    }

    /**
     * @see SzAbstractVo::toEntireArray
     */
    public function toEntireArray($needEncode = false)
    {
        return array(
            'userId' => $this->getUserId(),
            'buildingId' => $this->getBuildingId(),
            'number' => $this->getNumber(),
            'level' => $this->getLevel(),
            'endTime' => $this->getEndTime(),
            'exp' => $this->getExp(),
            'startTime' => $this->getStartTime(),
        );
    }

    /**
     * @see SzAbstractVo::toPureArray
     */
    public function toPureArray()
    {
        return array(
            $this->getUserId(),
            $this->getBuildingId(),
            $this->getNumber(),
            $this->getLevel(),
            $this->getEndTime(),
            $this->getExp(),
            $this->getStartTime(),
        );
    }

    public function getUserId()
    {
        return $this->userId;
    }

    public function setUserId($val)
    {
        $this->saveColumnStatus(0, $this->userId);
        $this->userId = $val;
    }

    public function getBuildingId()
    {
        return $this->buildingId;
    }

    public function setBuildingId($val)
    {
        $this->saveColumnStatus(1, $this->buildingId);
        $this->buildingId = $val;
    }

    public function getNumber()
    {
        return $this->number;
    }

    public function setNumber($val)
    {
        $this->saveColumnStatus(2, $this->number);
        $this->number = $val;
    }

    public function getLevel()
    {
        return $this->level;
    }

    public function setLevel($val)
    {
        $this->saveColumnStatus(3, $this->level);
        $this->level = $val;
    }

    public function getEndTime()
    {
        return $this->endTime;
    }

    public function setEndTime($val)
    {
        $this->saveColumnStatus(4, $this->endTime);
        $this->endTime = $val;
    }

    public function getExp()
    {
        return $this->exp;
    }

    public function setExp($val)
    {
        $this->saveColumnStatus(5, $this->exp);
        $this->exp = $val;
    }

    public function getStartTime()
    {
        return $this->startTime;
    }

    public function setStartTime($val)
    {
        $this->saveColumnStatus(6, $this->startTime);
        $this->startTime = $val;
    }

}